﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace TicketsPhone.FrontEnd.Models
{
    public class SesionModel
    {
        public static int IdUsuario { get { return int.Parse(HttpContext.Current.User.Identity.Name.Split(new char[] { '|' })[0]); } }
        public static string Email { get { return HttpContext.Current.User.Identity.Name.Split(new char[] { '|' })[1]; } }
        public static string NombreCompleto { get { return HttpContext.Current.User.Identity.Name.Split(new char[] { '|' })[2]; } }
        public static int IdEntidad { get { return int.Parse(HttpContext.Current.User.Identity.Name.Split(new char[] { '|' })[3]); } }
        public static int IdPerfil { get { return int.Parse(HttpContext.Current.User.Identity.Name.Split(new char[] { '|' })[4]); } }
        public static int IdSucursal { get { return int.Parse(HttpContext.Current.User.Identity.Name.Split(new char[] { '|' })[5]); } }
    }
}